package com.baomidou.ant.service;

import com.baomidou.ant.entity.ParentOrder;
import com.baomidou.ant.entity.WorkOrder;
import com.baomidou.ant.vo.request.*;
import com.baomidou.ant.vo.response.*;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author jobob
 * @since 2022-03-18
 */
public interface IWorkOrderService extends IService<WorkOrder> {
    //分页查询的方法
    IPage<ResponseOrderListVo> orderList(RequestListOrderVo requestListOrderVo);
    //根据工单号查询的方法
    WorkOrder queryByOrderNum(String orderNum);
    //更新工单方法
    boolean updateOrder(RequestUpdateOrderVo requestUpdateOrderVo);
    //新增子工单
    void addWorkOrder(ParentOrder parentOrder,String[] workerList);
    //转交方法
    boolean reWorker(RequestReWorkerVo vo);
    //获取工单详情方法
    ResponseOrderInfoVo getOrderInfo(WorkOrder workOrder);
    //人员详情接口
    ResponseWorkerInfoVo getWorkerInfo(WorkOrder workOrder);
    //得到指定工单的包含工序名的方法
    List<String> getProcessName(Integer id);
    //导出Excel表格的方法
    void exportTemplateProvinceAreaData(HttpServletResponse response,String orderIds);
    //    void exportTemplateProvinceAreaData(HttpServletResponse response);
    //工单总数展示
    int totalSize(RequestDtoVo requestDtoVo);
    //未完成工序的推送
    List<ResponsePutProcessVo> putProcess(WorkOrder workOrder);
    //人员分配检测方法---禁止一个人分配多个工序
    boolean checkWorker(String[] workerList);
    //导出生产流程单
    ResponseProductionFlowVo getFlow(String orderNum);
    //获取滞留信息
    IPage<ResponseRetentionOrderVo> retentionOrder(RequestRetentionOrderVo vo);
    //获取在产信息
    IPage<ResponseInProductionVo> inProduction(RequestInProductionVo vo);
    //删除上报记录改变改变工序
    void changeProcess(Integer orderId,Integer processId);
    //导出报表功能
    void exportRetentionInfo(HttpServletResponse response, String[]  data);
}
